package com.echo.code.spring.springbootdemo.scope;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Scope;

/**
 * Description
 *
 * @author baiyp
 * @version 1.0.0
 * @date 2019/04/27
 */
@Configuration
public class BookConfig {

  @Bean
  @Scope(value = "prototype")
  public Book book() {
    Book book = Book.builder().bookName("Core Java Ⅱ").build();
    return book;
  }
}
